function  lazyload(){
    var temp1=window.innerHeight||document.documentElement.clientHeight
    var temp2=document.documentElement.scrollTop||document.body.scrollTop
    var showImgHeight=temp1+temp2
    var imgObj=document.querySelectorAll('img')
    console.log(imgObj)
    imgObj.forEach(function(item){
        if(item.offsetTop<=showImgHeight){
            item.src=item.getAttribute('data')
        }

    })
}
lazyload()
window.onscroll=lazyload